package com.commander.spring.cloud.route;

import org.springframework.cloud.gateway.route.RouteDefinition;
import org.springframework.context.ApplicationEventPublisherAware;

/**
 * description:
 * <p>
 * Date: 2020-06-11
 * <p>
 * Time: 18:17
 *
 * @author zhangxin
 */
public interface ApplicationEventPublisherAwareService extends ApplicationEventPublisherAware {
	
	/**
	 * 添加路由
	 *
	 * @param definition
	 */
	void add(RouteDefinition definition);
	
	/**
	 * 删除路由
	 */
	void delete(String id);
	
	/**
	 * 更新路由
	 */
	void update(RouteDefinition definition);
	
	/**
	 * 刷新路由
	 */
	void refreshRoutes();
}
